package com.wxy.gxs.springbootprojectday20.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.ViewControllerRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;

@Configuration
public class CustomConfig  implements WebMvcConfigurer{
    @Override
    public void addViewControllers(ViewControllerRegistry registry) {
        registry.addViewController("/").setViewName("/test01");
        registry.addViewController("/index").setViewName("test01");
        registry.addViewController("/admin").setViewName("/test01");
    }
}
